<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" href="../../../../style.css" type="text/css" media="screen">
<link rel="stylesheet" href="../../../../print.css" type="text/css" media="print">
<meta content="ClientGeocoder,com.google.maps.services.ClientGeocoder,geocode,getBaseCountryCode,getViewport,resetCache,setBaseCountryCode,setViewport" name="keywords">
<title>com.google.maps.services.ClientGeocoder</title>
</head>
<body>
<script type="text/javascript" language="javascript" src="../../../../asdoc.js"></script><script type="text/javascript" language="javascript" src="../../../../cookies.js"></script><script type="text/javascript" language="javascript">
<!--
				asdocTitle = 'ClientGeocoder - Google Maps API for Flash Documentation';
				var baseRef = '../../../../';
				window.onload = configPage;
			--></script>
<table style="display:none" id="titleTable" cellspacing="0" cellpadding="0" class="titleTable">
<tr>
<td align="left" class="titleTableTitle">Google Maps API for Flash Documentation, Version 1.7a</td><td align="right" class="titleTableTopNav"><a onclick="loadClassListFrame('../../../../all-classes.html')" href="../../../../package-summary.html">All&nbsp;Packages</a>&nbsp;|&nbsp;<a onclick="loadClassListFrame('../../../../all-classes.html')" href="../../../../class-summary.html">All&nbsp;Classes</a>&nbsp;|&nbsp;<a onclick="loadClassListFrame('../../../../index-list.html')" href="../../../../all-index-A.html">Index</a>&nbsp;|&nbsp;<a href="../../../../index.html?com/google/maps/services/ClientGeocoder.html&amp;com/google/maps/services/class-list.html" id="framesLink1">Frames</a><a onclick="parent.location=document.location" href="" style="display:none" id="noFramesLink1">No&nbsp;Frames</a></td><td rowspan="3" align="right" class="titleTableLogo"><img alt="Adobe Logo" title="Adobe Logo" class="logoImage" src="../../../../images/logo.jpg"></td>
</tr>
<tr class="titleTableRow2">
<td align="left" id="subTitle" class="titleTableSubTitle">Class&nbsp;ClientGeocoder</td><td align="right" id="subNav" class="titleTableSubNav"><a href="#methodSummary">Methods</a></td>
</tr>
<tr class="titleTableRow3">
<td colspan="2">&nbsp;</td>
</tr>
</table>
<script type="text/javascript" language="javascript">
<!--
if (!isEclipse() || window.name != ECLIPSE_FRAME_NAME) {titleBar_setSubTitle("Class ClientGeocoder"); titleBar_setSubNav(false,false,false,false,false,false,true,false,false,false,false,false,false,false);}
--></script>
<div class="MainContent">
<table cellspacing="0" cellpadding="0" class="classHeaderTable">
<tr>
<td class="classHeaderTableLabel">Package</td><td><a onclick="javascript:loadClassListFrame('class-list.html')" href="package-detail.html">com.google.maps.services</a></td>
</tr>
<tr>
<td class="classHeaderTableLabel">Class</td><td class="classSignature">public final  class ClientGeocoder</td>
</tr>
<tr>
<td class="classHeaderTableLabel">Implements</td><td>flash.events.IEventDispatcher, <a href="../interfaces/IClientGeocoder.html">IClientGeocoder</a></td>
</tr>
</table>
<p></p>
 A ClientGeocoder object communicates with Google servers to obtain geocodes
 for user-specified addresses. In addition, a geocoder maintains its own cache
 of addresses, which allows repeated queries to be answered without a round
 trip to the server.
 <p></p>
<br>
<hr>
</div>
<a name="methodSummary"></a>
<div class="summarySection">
<div class="summaryTableTitle">Public Methods</div>
<table id="summaryTableMethod" class="summaryTable " cellpadding="3" cellspacing="0">
<tr>
<th>&nbsp;</th><th colspan="2">Method</th><th class="summaryTableOwnerCol">Defined&nbsp;by</th>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#ClientGeocoder()">ClientGeocoder</a>(countryCode:String = null, viewport:<a href="../LatLngBounds.html">LatLngBounds</a> = null)</div>
<div class="summaryTableDescription">
   Constructs a ClientGeocoder instance for performing geocoding.</div>
</td><td class="summaryTableOwnerCol">ClientGeocoder</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#geocode()">geocode</a>(address:String):void</div>
<div class="summaryTableDescription">
   Initiates a geocoding request.</div>
</td><td class="summaryTableOwnerCol">ClientGeocoder</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#getBaseCountryCode()">getBaseCountryCode</a>():String</div>
<div class="summaryTableDescription">
   Gets the current base country code from the ClientGeocoder.</div>
</td><td class="summaryTableOwnerCol">ClientGeocoder</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#getViewport()">getViewport</a>():<a href="../../maps/LatLngBounds.html">LatLngBounds</a>
</div>
<div class="summaryTableDescription">
   Gets the current viewport from the ClientGeocoder
      </div>
</td><td class="summaryTableOwnerCol">ClientGeocoder</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#resetCache()">resetCache</a>():void</div>
<div class="summaryTableDescription">
   Resets the geocoding cache, clearing all results retrieved by this
   and other ClientGeocoder objects.</div>
</td><td class="summaryTableOwnerCol">ClientGeocoder</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#setBaseCountryCode()">setBaseCountryCode</a>(country:String):void</div>
<div class="summaryTableDescription">
   Sets a base country code for the ClientGeocoder.</div>
</td><td class="summaryTableOwnerCol">ClientGeocoder</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#setViewport()">setViewport</a>(argViewport:<a href="../LatLngBounds.html">LatLngBounds</a>):void</div>
<div class="summaryTableDescription">
   Sets a viewport for the ClientGeocoder
   The geocoder will attempt to only return results
   which lie within or near the viewport
      </div>
</td><td class="summaryTableOwnerCol">ClientGeocoder</td>
</tr>
</table>
</div>
<script type="text/javascript" language="javascript">
<!--
showHideInherited();
--></script>
<div class="MainContent">
<a name="constructorDetail"></a>
<div class="detailSectionHeader">Constructor detail</div>
<a name="ClientGeocoder()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">ClientGeocoder</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">constructor</td>
</tr>
</table>
<div class="detailBody">
<code>public function ClientGeocoder(countryCode:String = null, viewport:<a href="../LatLngBounds.html">LatLngBounds</a> = null)</code><p>
   Constructs a ClientGeocoder instance for performing geocoding.
   </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">countryCode</span>:String</code> (default = <code>null</code>)<code></code> &mdash;  The base country code to use.
   </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">viewport</span>:<a href="../LatLngBounds.html">LatLngBounds</a></code> (default = <code>null</code>)<code></code> &mdash;  Viewport boundaries for the geocoder.
   </td>
</tr>
</table>
</div>
<a name="methodDetail"></a>
<div class="detailSectionHeader">Method detail</div>
<a name="geocode()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">geocode</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td>
</tr>
</table>
<div class="detailBody">
<code>public function geocode(address:String):void</code><p>
   Initiates a geocoding request.
   Dispatches GeocodingEvent.GEOCODING_SUCCESS or
   GeocodingEvent.GEOCODING_FAILURE on completion.
   
   </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">address</span>:String</code> &mdash;  Address to geocode.
   </td>
</tr>
</table>
<br>
<span class="label">Throws</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20"></td><td><code></code> &mdash;  A null or empty address will cause an ArgumentError
       to be thrown.
   </td>
</tr>
</table>
</div>
<a name="getBaseCountryCode()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">getBaseCountryCode</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function getBaseCountryCode():String</code><p>
   Gets the current base country code from the ClientGeocoder.
      </p><p></p>
<span class="label">Returns</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20"></td><td><code>String</code> &mdash; The current country code.
   </td>
</tr>
</table>
</div>
<a name="getViewport()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">getViewport</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function getViewport():<a href="../../maps/LatLngBounds.html">LatLngBounds</a></code><p>
   Gets the current viewport from the ClientGeocoder
      </p><p></p>
<span class="label">Returns</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20"></td><td><code><a href="../../maps/LatLngBounds.html">LatLngBounds</a></code> &mdash; 
                        The current viewport.
   
                        
                     </td>
</tr>
</table>
</div>
<a name="resetCache()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">resetCache</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function resetCache():void</code><p>
   Resets the geocoding cache, clearing all results retrieved by this
   and other ClientGeocoder objects.
   </p></div>
<a name="setBaseCountryCode()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">setBaseCountryCode</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function setBaseCountryCode(country:String):void</code><p>
   Sets a base country code for the ClientGeocoder.
      The base country code may bias the search towards results in the specified
   country. For example, if there is a city named Foo in countries XX and YY,
   setting base country code to YY causes geocoder to favor "Foo, YY"
   over "Foo, X". etc., and so on. This is designed to work exactly as
   if the caller were using the geocoder for the specified country.
   Specifying a base country code of "ES" will cause the geocoder to behave
   exactly as the geocoder at maps.google.es
      </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">country</span>:String</code> &mdash; The base country code to be set.
   </td>
</tr>
</table>
</div>
<a name="setViewport()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">setViewport</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function setViewport(argViewport:<a href="../LatLngBounds.html">LatLngBounds</a>):void</code><p>
   Sets a viewport for the ClientGeocoder
   The geocoder will attempt to only return results
   which lie within or near the viewport
      </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">argViewport</span>:<a href="../LatLngBounds.html">LatLngBounds</a></code> &mdash; The new viewport for the geocoder.
   </td>
</tr>
</table>
</div>
<br>
<br>
<hr>
<br>
<p></p>
<center class="copyright"> 
</center>
</div>
</body>
</html>
<!-- -->
